//
//  PayInfoEntity.m
//  QQplayground
//
//  Created by zhangxy on 2018/8/16.
//  Copyright © 2018年 zhang. All rights reserved.
//

#import "PayInfoEntity.h"

@implementation PayInfoEntity

- (instancetype)initWithDictionary:(NSDictionary *)dictionary
{
    self = [super init];
    if (self) {
        self = [PayInfoEntity yy_modelWithDictionary:dictionary];
        _attr_list = [[NSMutableArray alloc] init];
        NSArray *imgs = dictionary[@"attr_list"];
        for (NSDictionary *item in imgs) {
            [_attr_list addObject:[[VipTypeEntity alloc] initWithDictionary:item]];
        }
    }
    return self;
}


+ (NSDictionary<NSString *,id> *)modelCustomPropertyMapper
{
    return @{
             @"goods_id" : @"goods_id",
             @"goods_sn" : @"goods_sn",
             @"goods_name":@"goods_name",
             @"cat_id":@"cat_id"
             };
}

@end


@implementation VipTypeEntity

- (instancetype)initWithDictionary:(NSDictionary *)dictionary
{
    self = [super init];
    if (self) {
        self = [VipTypeEntity yy_modelWithDictionary:dictionary];
    }
    return self;
}


+ (NSDictionary<NSString *,id> *)modelCustomPropertyMapper
{
    return @{
             @"attr_id" : @"attr_id",
             @"name" : @"name",
             @"price":@"price",
             @"message":@"message",
             @"is_recommend":@"is_recommend"
             };
}

@end
